# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=python-sshpubkeys
_pkgname=sshpubkeys
pkgver=3.3.1
pkgrel=7
pkgdesc='SSH public key parser,'
arch=('any')
url='https://pypi.org/project/sshpubkeys/#files'
license=('BSD')
depends=('python' 'python-ecdsa' 'python-cryptography')
makedepends=('python-build' 'python-pip' 'python-wheel')
source=("https://files.pythonhosted.org/packages/source/${_pkgname::1}/$_pkgname/$_pkgname-$pkgver.tar.gz")
sha512sums=('e80de54a780796c6d5b3c083c302c27d6420cee033756df421258488d9ca0c6e230d6ac587d50cb850efd7ffa1157f55504e7d4ea7fca8e02caec9f44e389a4a')

build() {
  cd "$_pkgname-$pkgver"

  python -m build --wheel --outdir="$startdir/dist"
}

package() {
  cd "$_pkgname-$pkgver"

  pip install \
    --verbose \
    --disable-pip-version-check \
    --no-warn-script-location \
    --ignore-installed \
    --no-compile \
    --no-deps \
    --root="$pkgdir" \
    --prefix=/usr \
    --no-index \
    --find-links="file://$startdir/dist" \
    $_pkgname
}

